local drugsSkill = fk.CreateSkill {
  name = "drugs_skill",
}

drugsSkill:addEffect("cardskill", {
  prompt = "#drugs_skill",
  mod_target_filter = Util.TrueFunc,
  max_phase_use_time = 1,
  on_effect = function(self, room, effect)
    local to = effect.to
    if to.dead then return end
    room:addSkill("#drugs_trigger")
    local n = 1 + ((effect.extra_data or Util.DummyTable).additionalBuff or 0)
    if to:isWounded() then
      room:recover { num = n, skillName = "drugs_skill", who = to, recoverBy = effect.from, card = effect.card }
      if to.dead then return end
      room:addPlayerMark(to, "@drugsInflicted", n)
    end
    if not to:isWounded() then
      room:addPlayerMark(to, "drugs_buff-phase", n)
    end
  end,
  can_use = function(self, player, card, extra_data)
    local bypass = (extra_data and extra_data.bypass_times) or player.phase ~= Player.Play
    local tos = card:getFixedTargets(player, extra_data)
    return tos and table.find(tos, function(p)
      return not player:isProhibited(p, card)
      and (bypass or card.skill:withinTimesLimit(player, Player.HistoryPhase, card, card.name, p))
    end) ~= nil
  end,
})

Fk:loadTranslationTable{
  ["drugs_skill"] = "散",
  ["#drugs_skill"] = "已受伤：回复体力且下次受伤害+1；未受伤/因此回满血：你【杀】与【酒】次数+1",
}


return drugsSkill
